﻿using sipfe.Controllers.Base;
using sipfe.service.mante;
using sipfe.util;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;

namespace sipfe.Areas.Mante.Controllers
{
    public class DependenciaController : BaseSipfeController
    {
        public ActionResult IndexCab()
        {
            return View();
        }

        public ViewResult ListarAreaPoRegionForDerivar(string funcion, string tipo)
        {
            decimal IdRegion =  Decimal.Parse(Session[Constante.N_IDE_REGION].ToString());
            DependenciaManteService dependenciaManteService = new DependenciaManteService();
            ViewBag.ARBOL = new HtmlString(string.Format(dependenciaManteService.getDependenciasByRegion(IdRegion, funcion, tipo)));
            return View();
        }

    }
}